LQR-based anti-sway control method and system for lifting system

ABSTRACT

The present invention provides a linear quadratic regulator (LQR)-based anti-sway control method for a hoisting system, comprising the following steps: obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v m  and maximum acceleration a m  of the trolley; establishing a dynamic model of the hoisting system according to a Lagrange&#39;s equation, for the Lagrange&#39;s equation, the trolley displacement x, the spreader sway angle θ, and the rope length l of the hoisting system being selected as generalized coordinate directions; observing lumped disturbance d using an extended state observer, and compensating for same in a controller, the lumped disturbance d comprising the dynamic model error and external disturbance to the hoisting system; tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller. The LQR-based anti-sway control method for a hoisting system provided by the present invention can make the hoisting system operate more smoothly, reduce sway during operation, and quickly eliminate sway when in place while observing the lumped disturbance using an extended state observer.

CROSS-REFERENCE TO RELATED APPLICATIONS

This is a national phase of International Application No. PCT/CN2021/078138, filed 26 Feb. 2021, which claims priority to Chinese Application No. 202010252737.8, filed 2 Apr. 2020. The disclosure of each of these applications is incorporated herein by reference in its entirety for all purposes.

TECHNICAL FIELD

The present invention relates to the field of hoisting system transportation, and more particularly to a LQR-based anti-sway control method and system for a hoisting system.

BACKGROUND ART

Hoisting systems such as tire cranes, rail cranes, bridge cranes, etc. are widely used in the field of industrial transportation because of their strong load capacity and high flexibility. Tire cranes and bridge cranes are the two most common equipment in port terminals, which are respectively responsible for the container transportation between ships and internal trucks, between yards and internal trucks, and between yards and external trucks. At present, the hoisting system operation of port terminals is mostly manual. With the improvement of the requirements for throughput, gradually the manual operation mode can not meet the demand.

The operation process of the hoisting system is mainly divided into three stages: rising, falling and moving. In actual operation, the key link affecting the efficiency is the moving stage. Moving will cause the spreader of the hoisting system to shake, so that the container can not be accurately grasped when the spreader is lowered. Therefore, it is particularly important to control the anti-sway of the trolley or cart in the moving stage. Hoisting system is a typical underactuated system, which is a system with independent control input variable degrees of freedom less than the system degrees of freedom. The underactuated system has fewer actuators. Although it has the advantage of low cost, the underactuated system brings difficulties to the system control. For the movement of the hoisting system, the goal is to reach the designated position quickly and accurately and the sway angle is as small as possible in the process of movement, but the hoisting system can not directly act on the sway angle, but can only control its position or velocity.

Accordingly, there is a need to provide an anti-sway method, which can control the shaking of the hoisting system in the moving stage.

SUMMARY OF THE INVENTION

The technical problem to be solved by the present invention is to provide a LQR-based anti-sway control method and system for a hoisting system which can control the shaking of the hoisting system in the moving stage and quickly eliminate sway when in place by using an extended state observer and a linear quadratic regulator.

The technical solution adopted by the present invention to solve the above technical problem is to provide a LQR-based anti-sway control method for a hoisting system, characterized in that comprising the following steps:

obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley;

establishing a dynamic model of the hoisting system according to a Lagrange's equation, for the Lagrange's equation, the trolley displacement x, the spreader sway angle θ, and the rope length l of the hoisting system being selected as generalized coordinate directions; observing lumped disturbance d using an extended state observer, and compensating for same in a controller, the lumped disturbance d comprising the dynamic model error and external disturbance to the hoisting system; tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller.

Optionally, obtaining the planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley specifically comprising the following formula:

${{\overset{.}{x}}_{r}(t)} = \left\{ \begin{matrix} {{\frac{v_{m}}{2}\left( {1 - {\cos\pi\frac{2a_{m}}{v_{m}}t}} \right)},{0 < t \leq \frac{v_{m}}{2a_{m}}}} \\ {v_{m},{\frac{v_{m}}{2a_{m}} < t \leq {\frac{v_{m}}{2a_{m}} + t_{c}}}} \\ {{\frac{v_{m}}{2}\left\lbrack {1 + {\cos\pi\frac{2a_{m}}{v_{m}}\left( {t - \frac{v_{m}}{2a_{m}} - t_{c}} \right)}} \right\rbrack},{{\frac{v_{m}}{2a_{m}} + t_{c}} \leq t \leq {\frac{v_{m}}{a_{m}} + t_{c}}}} \end{matrix} \right.$ wherein, t is the running time of the trolley, t_(c) is the constant velocity time of the trolley, {dot over (x)}_(r)(t) is the real-time velocity of the planned path of the trolley, obtaining the planned real-time path of the trolley by integrating, the constant velocity time t_(c) is determined according to the target position path of the trolley. Optionally, establishing a nonlinear equation of the system according to the Lagrange equation as follows:

$\left\{ \begin{matrix} {{{\left( {M + m} \right)\overset{¨}{x}} + {m\overset{¨}{l}\sin\theta} + {2m\overset{.}{l}\overset{.}{\theta}\cos\theta} + {{ml}\overset{¨}{\theta}\cos\theta} - {{ml}{\overset{.}{\theta}}^{2}\sin\theta} + {\mu\overset{.}{x}}} = F} \\ {{{2\overset{.}{l}\overset{.}{\theta}} + {l\overset{¨}{\theta}} + {\overset{¨}{x}\cos\theta} + {g\sin\theta}} = 0} \\ {{{m\overset{¨}{l}} + {m\overset{¨}{x}\sin\theta} - {{ml}{\overset{.}{\theta}}^{2}} - {{mg}\cos\theta}} = F_{1}} \end{matrix} \right.$ wherein, M is the trolley mass, m is the spreader mass, and l is the rope length, θ is the spreader sway angle, μ is the friction coefficient, x is the trolley displacement, F is the motor force, F₁ is the pulling force between the trolley and the spreader, and g is the gravitational acceleration.

Optionally, the rope length l remains unchanged, the spreader sway angle θ is greater than −5° and less than 5°, simplifying the nonlinear equation as follows:

${\overset{.}{l} = {\overset{¨}{l} = 0}},{{\cos\theta} \approx 1},{{\sin\theta} \approx \theta}$ ${{\overset{¨}{\theta}\cos\theta} - {{\overset{.}{\theta}}^{2}\sin\theta}} = {{\frac{d}{dt}\left( {\overset{.}{\theta}\cos\theta} \right)} = {{\frac{d}{dt}\left( \overset{.}{\theta} \right)} = \overset{¨}{\theta}}}$ obtaining the following linearization equation by further linearization:

$\left\{ \begin{matrix} {{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{.}{x}} + F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$

Optionally, obtaining the following equation by introducing a lumped disturbance d in the linearization equation:

$\left\{ \begin{matrix} {{{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{.}{x}} - d} = F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$ taking the state variables as the trolly displacement x and spreader sway angle θ, input as motor force F, establishing the following state equation, and rewriting the said equation into the standard state equation form in control theory:

$\left\{ \begin{matrix} {\overset{.}{X} = {{AX} + {B\left( {u + d} \right)}}} \\ {y_{m} = {C_{m}X}} \end{matrix} \right.$ wherein:

$A = \begin{bmatrix} 0 & 1 & 0 & 0 \\ 0 & {- \frac{\mu}{M}} & \frac{mg}{M} & 0 \\ 0 & 0 & 0 & 1 \\ 0 & \frac{\mu}{Ml} & {- \frac{\left( {M + m} \right)g}{Ml}} & 0 \end{bmatrix}$ $B = \begin{bmatrix} 0 & \frac{1}{M} & 0 & {- \frac{1}{Ml}} \end{bmatrix}^{T}$ $C_{m} = \left\lbrack \begin{matrix} 1 & 0 & 0 & \left. 0 \right\rbrack \end{matrix} \right.$ u is the control variable, X is the vector representing the system state, y_(m) is the system output, A is the system state matrix, B is the system input matrix, Cm is the system output matrix, and the subscript m represents the directly observable.

Optionally, a new variable x₅=d is introduced into the state equation, d is used to represent lumped disturbance:

$\left\{ \begin{matrix} {{\overset{˙}{x}}_{1} = x_{2}} \\ {{\overset{˙}{x}}_{2} = {\frac{1}{M}\left( {{{- \mu}x_{2}} + {mgx_{3}} + x_{5} + u} \right)}} \\ {{\overset{˙}{x}}_{3} = x_{4}} \\ {{\overset{.}{x}}_{4} = {{- \frac{1}{Ml}}\left( {{{- \mu}x_{2}} + {\left( {M + m} \right)gx_{3}} + x_{5} + u} \right)}} \\ {{\overset{.}{x}}_{5} = \overset{.}{d}} \end{matrix} \right.$ y_(m) = C_(m)X wherein, x₁ is the displacement of the trolley, x₂ is the trolley velocity, x₃ is the spreader sway angle, x₄ is the angle velocity of the spreader sway angle.

Optionally, in order to realize the observation of system state and lumped disturbance, the extended state observer is designed as follows:

$\left\{ \begin{matrix} {{\overset{.}{\overset{\hat{}}{x}}}_{1} = {{\overset{\hat{}}{x}}_{2} + {l_{1}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{2} = {{\frac{1}{M}\left( {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {mg{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right)} + {l_{2}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{3} = {{\overset{\hat{}}{x}}_{4} + {l_{3}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {\left( {M + m} \right)g{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right\rbrack}} + {l_{4}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{5} = {l_{5}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}} \end{matrix} \right.$ wherein, {circumflex over (x)}₁, {circumflex over (x)}₂, {circumflex over (x)}₃, {circumflex over (x)}₄, {circumflex over (x)}₅ is the observed value of x₁, x₂, x₃, x₄, x₅, l₁, l₂, l₃, l₄, l₅ is the observer gain to be designed.

Optionally, tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller comprising the use of the following composite control: u=K _(x)[{circumflex over (x)} ₁ {circumflex over (x)} ₂ {circumflex over (x)} ₃ x ₄]−{circumflex over (x)} ₅ wherein, K_(x) is the feedback control gain.

The technical solution adopted by the present invention to solve the above technical problem is to provide a LQR-based anti-sway control system for a hoisting system, comprising: a server which comprising a memory, a processor and a computer program stored on the memory and running on the processor, when the the program executed by the processor, the said LQR-based anti-sway control method for the hoisting system is executed.

The technical solution adopted by the present invention to solve the above technical problem is to provide a computer readable storage medium on which a computer program is stored, when the program is executed by a processor, the said LQR-based anti-sway control method for the hoisting system is executed.

Compared to the prior art, the technical solutions of embodiments of the present invention have the following advantageous effects.

The LQR-based anti-sway control method for a hoisting system provided by the present invention, obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley and establishing a dynamic model of the hoisting system according to a Lagrange's equation, which can make the hoisting system operate more smoothly, reduce sway during operation, and quickly eliminate sway when in place while observing the lumped disturbance using an extended state observer.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a physical schematic diagram of the two-dimensional movement of the hoisting system according to an embodiment of the present invention;

FIG. 2 is a flow chart of a LQR-based anti-sway control method for a hoisting system according to an embodiment of the present invention;

FIG. 3 is a control structure diagram of a LQR-based anti-sway control method for a hoisting system according to an embodiment of the present invention;

FIG. 4 is a comparison diagram of the trolley displacement, angle and control amount whether a planned path is used in an embodiment of the present invention;

FIG. 5 shows the control effect comparison diagram between the LQR controller based on the extended state observer in an embodiment of the present invention and other controllers.

DETAILED DESCRIPTION OF THE INVENTION

The present invention will be further described below in combination with the accompanying drawings and embodiments.

In the following description, many specific details are set forth in order to provide a thorough understanding of the present invention. However, it will be apparent to those skilled in the art that the present invention can be practiced without these specific details. Therefore, the specific details are only exemplary, and the specific details may vary from the spirit and scope of the unrestrained and are still considered to be within the spirit and scope of the present invention.

The hoisting system in this embodiment can be used for port logistics. The hoisting system includes a crane, which includes but is not limited to a tire crane, a straddle carrier and a stacker. The following takes a tire crane as an example to illustrate the working principle of the automatic deviation correction control method of the hoisting system of the present invention.

Now refer to FIG. 1 , FIG. 1 is a physical schematic diagram of the two-dimensional movement of the hoisting system according to an embodiment of the present invention. Wherein, M is the trolley mass, m is the spreader mass, and l is the rope length, θ is the spreader sway angle, is the friction coefficient, x is the trolley displacement, F is the motor force, F₁ is the pulling force between the trolley and the spreader, and g is the gravitational acceleration.

FIG. 2 is a flow chart of a Linear Quadratic Regulator (LQR)-based anti-sway control method for a hoisting system according to an embodiment of the present invention. First step 101: obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley. Then step 102: establishing a dynamic model of the hoisting system according to a Lagrange's equation, for the Lagrange's equation, the trolley displacement x, the spreader sway angle θ, and the rope length l of the hoisting system being selected as generalized coordinate directions. Then step 103: observing lumped disturbance d using an extended state observer, and compensating for same in a controller, the lumped disturbance d comprising the dynamic model error and external disturbance to the hoisting system. Last step 104: tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller.

Wherein, a Q matrix and an R matrix are inherent matrices in LQR (linear quadratic regulator) method. Q is the weight matrix of state variables and diagonal matrix. The larger the corresponding value of Q, the more important the state is in the performance function. R is the weight of the control quantity. The larger the corresponding value of R, the more important the state is in the performance function.

In a particular implementation, obtaining the planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley specifically comprising the following formula:

${{\overset{˙}{x}}_{r}(t)} = \left\{ \begin{matrix} {{\frac{v_{m}}{2}\left( {1 - {\cos\pi\frac{2a_{m}}{v_{m}}t}} \right)},{0 < t \leq \frac{v_{m}}{2a_{m}}}} \\ {v_{m},{\frac{v_{m}}{2a_{m}} < t \leq {\frac{v_{m}}{2a_{m}} + t_{c}}}} \\ {{\frac{v_{m}}{2}\left\lbrack {1 + {\cos\pi\frac{2a_{m}}{v_{m}}\left( {t - \frac{v_{m}}{2a_{m}} - t_{c}} \right)}} \right\rbrack},{{\frac{v_{m}}{2a_{m}} + t_{c}} \leq t \leq {\frac{v_{m}}{a_{m}} + t_{c}}}} \end{matrix} \right.$ wherein, t is the running time of the trolley, t_(c) is the constant velocity time of the trolley, {dot over (x)}_(r)(t) is the real-time velocity of the planned path of the trolley, obtaining the planned real-time path of the trolley by integrating {dot over (x)}_(r)(t), the constant velocity time t_(c) is determined according to the target position path of the trolley.

For the vibration system with multiple degrees of freedom, the Lagrange equation in the dynamic model of the hoisting system established according to the Lagrange equation is as follows:

$\left\{ \begin{matrix} {{L\left( {q,\overset{.}{q}} \right)} = {{T\left( {q,\overset{.}{q}} \right)} - {V\left( {q,\overset{.}{q}} \right)}}} \\ {{{\frac{d}{dt}\left( \frac{\partial L}{\partial{\overset{˙}{q}}_{i}} \right)} - \frac{\partial L}{\partial q_{i}}} = Q_{i}} \end{matrix} \right.$ Wherein, q represents generalized coordinates, Q represents generalized force, L represents Lagrangian operator, T represents kinetic energy of the system, V represents potential energy of the system.

The crane operation scenario is relatively complex, and the following assumptions are first made when modeling:

1. During the movement of the trolley or the cart, the trolley or the cart is in a static state.

2. There is friction between the trolley and the track, and the friction is proportional to the trolley velocity.

3. Because cranes mostly use spreaders with eight rope, the spreaders are regarded as particles in two-dimensional motion.

4. Ignore the influence of air resistance, wind force, friction between trolley and steel wire rope and other factors.

Selecting three generalized coordinates of the rope length l, the spreader sway angle θ and the trolley displacement x according to the said dynamic differential equation to establish a nonlinear equation of the system according to the Lagrange equation as follows:

$\left\{ \begin{matrix} {{{\left( {M + m} \right)\overset{¨}{x}} + {m\overset{¨}{l}\sin\theta} + {2m\overset{.}{l}\overset{˙}{\theta}\cos\theta} + {ml\overset{¨}{\theta}\cos\theta} - {ml{\overset{˙}{\theta}}^{2}\sin\theta} + {\mu\overset{.}{x}}} = F} \\ {{{2\overset{.}{l}\overset{˙}{\theta}} + {l\overset{¨}{\theta}} + {\overset{¨}{x}\cos\theta} + {g\sin\theta}} = 0} \\ {{{m\overset{¨}{l}} + {m\overset{¨}{x}\sin\theta} - {ml{\overset{˙}{\theta}}^{2}} - {mg\cos\theta}} = F_{1}} \end{matrix} \right.$ wherein, M is the trolley mass, m is the spreader mass, and l is the rope length, θ is the spreader sway angle, is the friction coefficient, x is the trolley displacement, F is the motor force, F₁ is the pulling force between the trolley and the spreader, and g is the gravitational acceleration.

In the process of crane operation, the movement of the cart and the trolley is often carried out separately, so it can be considered that the rope length l remains unchanged. At the same time, because the steel wire rope length l is relatively long, in order to ensure the safety of operation and avoid collision, the spreader sway angle θ can not be too big, the spreader sway angle θ is greater than −5° and less than 5°, simplifying the nonlinear equation as follows:

${\overset{.}{l} = {\overset{¨}{l} = 0}},{{\cos\theta} \approx 1},{{\sin\theta} \approx \theta}$ ${{\overset{¨}{\theta}\cos\theta} - {{\overset{˙}{\theta}}^{2}\sin\theta}} = {{\frac{d}{dt}\left( {\overset{˙}{\theta}\cos\theta} \right)} = {{\frac{d}{dt}\left( \overset{˙}{\theta} \right)} = \overset{¨}{\theta}}}$ obtaining the following linearization equation by further linearization:

$\left\{ \begin{matrix} {{{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{.}{x}}} = F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$ Obtaining the following equation by introducing the lumped disturbance d in the linearization equation:

$\left\{ \begin{matrix} {{{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{.}{x}}} = F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$ taking the state variables as the trolley displacement x and spreader sway angle θ, input as motor force F, establishing the following state equation, and rewriting the said equation into the standard state equation form in control theory:

$\left\{ \begin{matrix} {\overset{˙}{X} = {{AX} + {B\left( {u + d} \right)}}} \\ {y_{m} = {C_{m}X}} \end{matrix} \right.$ wherein:

$A = \begin{bmatrix} 0 & 1 & 0 & 0 \\ 0 & {- \frac{\mu}{M}} & \frac{mg}{M} & 0 \\ 0 & 0 & 0 & 1 \\ 0 & \frac{\mu}{Ml} & {- \frac{\left( {M + m} \right)g}{Ml}} & 0 \end{bmatrix}$ $B = \begin{bmatrix} 0 & \frac{1}{M} & 0 & {- \frac{1}{Ml}} \end{bmatrix}^{T}$ $C_{m} = \begin{bmatrix} 1 & 0 & 0 & 0 \end{bmatrix}$ u is the control variable, X is the vector representing the system state, y_(m) is the system output, A is the system state matrix, B is the system input matrix, Cm is the system output matrix, and the subscript m represents the directly observable.

A new variable x₅=d is introduced into the state equation, d is used to represent lumped disturbance:

$\left\{ \begin{matrix} {{\overset{˙}{x}}_{1} = x_{2}} \\ {{\overset{˙}{x}}_{2} = {\frac{1}{M}\left( {{{- \mu}x_{2}} + {mgx_{3}} + x_{5} + u} \right)}} \\ {{\overset{˙}{x}}_{3} = x_{4}} \\ {{\overset{.}{x}}_{4} = {{- \frac{1}{Ml}}\left( {{{- \mu}x_{2}} + {\left( {M + m} \right)gx_{3}} + x_{5} + u} \right)}} \\ {{\overset{.}{x}}_{5} = \overset{.}{d}} \end{matrix} \right.$ y_(m) = C_(m)X wherein, x₁ is the trolley displacement, x₂ is the trolley velocity, x₃ is the spreader sway angle, x₄ is the angle velocity of the spreader sway angle.

In actual operation, the spreader sway angle θ It is difficult to measure accurately, and the system modeling errors including the change of lifting weight and rope length l, as well as external disturbances including wind, will affect the control performance. The extended state observer is used to observe the lumped disturbance d and compensate in the controller, the lumped disturbance d includes system modeling errors and external disturbances.

A new variable x₅=d is introduced into the state equation, d is used to represent lumped disturbance:

$\left\{ \begin{matrix} {{\overset{˙}{x}}_{1} = x_{2}} \\ {{\overset{˙}{x}}_{2} = {\frac{1}{M}\left( {{{- \mu}x_{2}} + {mgx_{3}} + x_{5} + u} \right)}} \\ {{\overset{˙}{x}}_{3} = x_{4}} \\ {{\overset{.}{x}}_{4} = {{- \frac{1}{Ml}}\left( {{{- \mu}x_{2}} + {\left( {M + m} \right)gx_{3}} + x_{5} + u} \right)}} \\ {{\overset{.}{x}}_{5} = \overset{.}{d}} \end{matrix} \right.$ y_(m) = C_(m)X wherein, x₁ is the trolley displacement, x₂ is the trolley velocity, x₃ is the spreader sway angle, x₄ is the angle velocity of the spreader sway angle.

The system modeling error and external disturbance d appear in the two channels x₂, x₄ with equal values, so the state equation is rewritten as follows:

$\left\{ \begin{matrix} {{\overset{˙}{x}}_{1} = x_{2}} \\ {{\overset{˙}{x}}_{2} = {{{- \frac{\mu}{M}}x_{2}} + {\frac{mg}{M}x_{3}} + {\frac{1}{M}u} + d}} \\ {{\overset{˙}{x}}_{3} = x_{4}} \\ {{\overset{.}{x}}_{4} = {{{- \frac{\mu}{Ml}}x_{2}} + {{- \frac{\left( {M + m} \right)g}{lM}}x_{3}} - {\frac{1}{Ml}u} + d}} \end{matrix} \right.$

In order to realize the observation of system state and lumped disturbance, the extended state observer is designed as follows:

$\left\{ \begin{matrix} {{\overset{.}{\overset{\hat{}}{x}}}_{1} = {{\overset{\hat{}}{x}}_{2} + {l_{1}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{2} = {{\frac{1}{M}\left( {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {mg{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right)} + {l_{2}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{3} = {{\overset{\hat{}}{x}}_{4} + {l_{3}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {\left( {M + m} \right)g{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right\rbrack}} + {l_{4}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{5} = {l_{5}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}} \end{matrix} \right.$ wherein, {circumflex over (x)}₁, {circumflex over (x)}₂, {circumflex over (x)}₃, {circumflex over (x)}₄, {circumflex over (x)}₅ is the observed value of x₁, x₂, x₃, x₄, x₅, l₁, l₂, l₃, l₄, l₅ is the observer gain to be designed.

In a particular implementation, tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller comprising the use of the following composite control: U=K _(x)[{circumflex over (x)} ₁ {circumflex over (x)} ₂ {circumflex over (x)} ₃ {circumflex over (x)} ₄]−{circumflex over (x)} ₅ wherein, K_(x) is the feedback control gain.

FIG. 3 is a control structure diagram of a LQR-based anti-sway control method for a hoisting system according to an embodiment of the present invention. Now refer to FIG. 3 , wherein, x* is the target position of the trolley, v_(m) is the maximum trolley velocity, a m is the maximum acceleration, x_(r) is the planned real-time path of the trolley, K_(x) is the feedback control gain, U is the control quantity, that is, the controller output, d is the lumped disturbance of the system modeling error and external disturbance, e₁ is the state error, {circumflex over (d)} is the disturbance observation value, and the expanded state observer is used to observe the lumped disturbance d and compensate it in the controller, y_(o), y_(m) are output and observable output respectively. The stability of the LQR-based anti-sway control method of the hoisting system is analyzed. It is assumed that the lumped interference d and its derivatives {dot over (d)} are bounded, and that the lumped interference d has a constant value in the steady state, that is, d satisfies

lim t → ∞ d ⁡ ( t ) = d s lim t → ∞ d ˙ ( t ) = 0 , wherein d_(s) is a constant vector.

$\left\{ \begin{matrix} {{\overset{.}{\overset{\hat{}}{x}}}_{1} = {{\overset{\hat{}}{x}}_{2} + {l_{1}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{2} = {{\frac{1}{M}\left( {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {mg{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right)} + {l_{2}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{3} = {{\overset{\hat{}}{x}}_{4} + {l_{3}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {\left( {M + m} \right)g{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right\rbrack}} + {l_{4}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{5} = {l_{5}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}} \end{matrix} \right.$

Assuming that the above conditions are satisfied, the extended state observer designed l₁, l₂, l₃, l₄, l₅ in the above equation is asymptotically stable.

The error system can be written as the following equation:

$\left\{ \begin{matrix} {{\overset{.}{e}}_{1} = {e_{2} + {l_{1}e_{1}}}} \\ {{\overset{.}{e}}_{2} = {{\frac{1}{M}\left( {{{- \mu}e_{2}} + {mge_{3}} + e_{5} + u} \right)} + {l_{2}e_{1}}}} \\ {{\overset{.}{e}}_{3} = {e_{4} + {l_{3}e_{1}}}} \\ {{\overset{.}{e}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}e_{2}} + {\left( {M + m} \right)ge_{3}} + e_{5} + u} \right\rbrack}} + {l_{4}e_{1}}}} \\ {{\overset{.}{e}}_{5} = {{l_{5}e_{1}} - \overset{˙}{d}}} \end{matrix} \right.$

Wherein, e_(i)={circumflex over (x)}_(i)−x_(i), (i=1, 2, 3, 4, 5) represents the estimation error, the coefficient matrix Ā of the error system is as follows, Ā is a Hurwitz matrix:

$\overset{¯}{A} = \begin{bmatrix} l_{1} & 1 & 0 & 0 & 0 \\ l_{2} & {- \frac{\mu}{M}} & {\frac{m}{M}g} & 0 & 1 \\ l_{3} & 0 & 0 & 1 & 0 \\ l_{4} & \frac{\mu}{Ml} & {{- \frac{M + m}{Ml}}g} & 0 & 1 \\ l_{5} & 0 & 0 & 0 & 0 \end{bmatrix}$

According to the Input State Stability (ISS) theory, if Ā is a Hurwitz matrix, it can be concluded that the error system conforms to the ISS theory. It is assumed that the lumped interference d and its derivatives {dot over (d)} are bounded, and that the lumped interference d has a constant value in the steady state, the stability of the extended state observer can be achieved. Therefore, the error dynamics of the extended state observer are asymptotically stable and satisfies

${\lim\limits_{t\rightarrow\infty}e_{i}} = 0.$ $\left\{ \begin{matrix} {\overset{˙}{X} = {{AX} + {B\left( {u + d} \right)}}} \\ {y_{m} = {C_{m}X}} \end{matrix} \right.$ $u = {{K_{x}\overset{\hat{}}{X}} + \overset{\hat{}}{d}}$

Combining the above two formulas, the following closed-loop equations of the crane system can be obtained: {dot over (X)}=(A+BK _(x))X Wherein, K_(x) is the feedback control gain, {circumflex over (d)} is the observed value.

The control performance of the LQR-based anti-sway control method of the hoisting system in the embodiment is verified by simulation. After the Q matrix and R matrix are configured as follows, they can be calculated K_(x)=[8.94, 19.52, −8.78, 4.47]

${Q = \begin{bmatrix} {80} & 0 & 0 & 0 \\ 0 & 180 & 0 & 0 \\ 0 & 0 & 1800 & 0 \\ 0 & 0 & 0 & {20} \end{bmatrix}},{R = 1}$

The observer gain in the following formula is designed as L=diag(100, 397, −776, 1943, −2894)

$\left\{ \begin{matrix} {{\overset{.}{\overset{\hat{}}{x}}}_{1} = {{\overset{\hat{}}{x}}_{2} + {l_{1}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{2} = {{\frac{1}{M}\left( {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {mg{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right)} + {l_{2}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{3} = {{\overset{\hat{}}{x}}_{4} + {l_{3}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {\left( {M + m} \right)g{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right\rbrack}} + {l_{4}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{5} = {l_{5}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}} \end{matrix} \right.$

In the simulation experiment, the effects of whether to use a planned path and various controllers are compared. In the first simulation, the control effects of whether to use a planned path are compared. In the second simulation, the effects of various controllers are compared, and the anti-interference performance of the proposed method is tested, that is, increasing the disturbance when the system reaches the steady state (20 s).

FIG. 4 is a comparison diagram of the trolley displacement, angle and control amount whether a planned path is used in an embodiment of the present invention. FIG. 5 shows the control effect comparison diagram between the LQR controller based on the extended state observer in an embodiment of the present invention and other controllers. PID marked in FIG. 5 refers to PID (proportional integral derivative control) controller, which is one of the most commonly used controllers. LQR+ESO (Extended State Observer) marked in FIG. 5 represents the combination of extended state observer and LQR controller. It is obvious from these two figures that, compared with not using a planned path, although it is slow in place by using a planned path, but its spreader sway angle is smaller and its impact on the actuator is smaller. LQR controller can use a Q matrix and an R matrix to configure the weight of the trolley displacement, spreader sway angle and other state variables, and ESO extended state observer can observe the system disturbance. Therefore, compared with PID controller, LQR controller based on ESO extended state observer can better track the path, and the spreader sway angle is smaller. When the system disturbance occurs, it can also quickly recover without static error under the control of this controller.

The embodiment of the present invention also provides a LQR-based anti-sway control system for a hoisting system, comprising: a server which comprising a memory, a processor and a computer program stored on the memory and running on the processor, when the the program executed by the processor, the said LQR-based anti-sway control method for the hoisting system is executed.

The embodiment of the present invention also provides a computer readable storage medium on which a computer program is stored, when the program is executed by a processor, the said LQR-based anti-sway control method for the hoisting system is executed.

In summary, a LQR-based anti-sway control method and system for a hoisting system provided by the present invention obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a m of the trolley and establishing a dynamic model of the hoisting system according to a Lagrange's equation, which can make the hoisting system operate more smoothly, reduce sway during operation, and quickly eliminate sway when in place while observing the lumped disturbance using an extended state observer.

Although the present invention has been disclosed as above in a preferred embodiment, it is not intended to limit the present invention. Any person skilled in the art can make some modifications and improvements without departing from the spirit and scope of the present invention. Therefore, the scope of protection of the present invention should be subject to those defined in the claims. 

The invention claimed is:
 1. A LQR-based anti-sway control method for a hoisting system, characterized in that comprising the following steps: obtaining a target position of a trolley, and obtaining a planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley; establishing a dynamic model of the hoisting system according to a Lagrange's equation, for the Lagrange's equation, the trolley displacement x, the spreader sway angle θ, and the rope length l of the hoisting system being selected as generalized coordinate directions; observing lumped disturbance d using an extened state observer, and compensating for same in a controller, the lumped disturbance d comprising the dynamic model error and external disturbance to the hoisting system; tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller; wherein, obtaining the planned real-time path of the trolley according to the maximum velocity v_(m) and maximum acceleration a_(m) of the trolley specifically comprising the following formula: ${{\overset{˙}{x}}_{r}(t)} = \left\{ \begin{matrix} {{\frac{v_{m}}{2}\left( {1 - {\cos\pi\frac{2a_{m}}{v_{m}}t}} \right)},{0 < t \leq \frac{v_{m}}{2a_{m}}}} \\ {v_{m},{\frac{v_{m}}{2a_{m}} < t \leq {\frac{v_{m}}{2a_{m}} + t_{c}}}} \\ {{\frac{v_{m}}{2}\left\lbrack {1 + {\cos\pi\frac{2a_{m}}{v_{m}}\left( {t - \frac{v_{m}}{2a_{m}} - t_{c}} \right)}} \right\rbrack},{{\frac{v_{m}}{2a_{m}} + t_{c}} \leq t \leq {\frac{v_{m}}{a_{m}} + t_{c}}}} \end{matrix} \right.$ wherein, t is the running time of the trolley, t_(c) is the constant velocity time of the trolley, {dot over (x)}_(r)(t) is the real-time velocity of the planned path of the trolley, obtaining the planned real-time path of the trolley by integrating {dot over (x)}_(r)(t), the constant velocity time t_(c) is determined according to the target position path of the trolley.
 2. The LQR-based anti-sway control method for the hoisting system according to claim 1, characterized in that establishing a nonlinear equation of the system according to the Lagrange equation as follows: $\left\{ \begin{matrix} {{{\left( {M + m} \right)\overset{¨}{x}} + {m\overset{¨}{l}\sin\theta} + {2m\overset{.}{l}\overset{˙}{\theta}\cos\theta} + {ml\overset{¨}{\theta}\cos\theta} - {ml{\overset{˙}{\theta}}^{2}\sin\theta} + {\mu\overset{.}{x}}} = F} \\ {{{2\overset{.}{l}\overset{.}{\theta}} + {l\overset{¨}{\theta}} + {\overset{¨}{x}\cos\theta} + {g\sin\theta}} = 0} \\ {{{m\overset{¨}{l}} + {m\overset{¨}{x}\sin\theta} - {ml{\overset{˙}{\theta}}^{2}} - {mg\cos\theta}} = F_{1}} \end{matrix} \right.$ wherein, M is the trolley mass, m is the spreader mass, and l is the rope length, θ is the spreader sway angle, μ is the friction coefficient, x is the trolley displacement, F is the motor force, F₁ is the pulling force between the trolley and the spreader, and g is the gravitational acceleration.
 3. The LQR-based anti-sway control method for the hoisting system according to claim 2, characterized in that the rope length l remains unchanged, the spreader sway angle θ is greater than −5° and less than 5° , simplifying the nonlinear equation as follows: ${\overset{.}{l} = {\overset{¨}{l} = 0}},{{\cos\theta} \approx 1},{{\sin\theta} \approx \theta}$ ${{\overset{¨}{\theta}\cos\theta} - {{\overset{˙}{\theta}}^{2}\sin\theta}} = {{\frac{d}{dt}\left( {\overset{˙}{\theta}\cos\theta} \right)} = {{\frac{d}{dt}\left( \overset{˙}{\theta} \right)} = \overset{¨}{\theta}}}$ obtaining the following linearization equation by further linearization: $\left\{ \begin{matrix} {{{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{.}{x}}} = F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$
 4. The LQR-based anti-sway control method for the hoisting system according to claim 3, characterized in that obtaining the following equation by introducing a lumped disturbance d in the linearization equation: $\left\{ \begin{matrix} {{{M\overset{¨}{x}} - {{mg}\theta} + {\mu\overset{˙}{x}} - d} = F} \\ {{{l\overset{¨}{\theta}} + \overset{¨}{x} + {g\theta}} = 0} \end{matrix} \right.$ taking the state variables as the trolley displacement x and spreader sway angle θ, input as motor force F, establishing the following state equation, and rewriting the said equation into the standard state equation form in control theory: $\left\{ \begin{matrix} {\overset{˙}{X} = {{AX} + {B\left( {u + d} \right)}}} \\ {y_{m} = {C_{m}X}} \end{matrix} \right.$ wherein: $A = \begin{bmatrix} 0 & 1 & 0 & 0 \\ 0 & {- \frac{\mu}{M}} & \frac{mg}{M} & 0 \\ 0 & 0 & 0 & 1 \\ 0 & \frac{\mu}{Ml} & {- \frac{\left( {M + m} \right)g}{Ml}} & 0 \end{bmatrix}$ $B = \begin{bmatrix} 0 & \frac{1}{M} & 0 & {- \frac{1}{Ml}} \end{bmatrix}^{T}$ $C_{m} = \begin{bmatrix} 1 & 0 & 0 & 0 \end{bmatrix}$ u is the control variable, X is the vector representing the system state, y_(m) is the system output, A is the system state matrix, B is the system input matrix, C_(m) is the system output matrix, and the subscript m represents the directly observable.
 5. The LQR-based anti-sway control method for the hoisting system according to claim 4, characterized in that a new variable x₅=d is introduced into the state equation, d is used to represent lumped disturbance: $\left\{ \begin{matrix} {{\overset{˙}{x}}_{1} = x_{2}} \\ {{\overset{.}{x}}_{2} = {\frac{1}{M}\left( {{{- \mu}x_{2}} + {mgx_{3}} + x_{5} + u} \right)}} \\ {{\overset{˙}{x}}_{3} = x_{4}} \\ {{\overset{.}{x}}_{4} = {{- \frac{1}{Ml}}\left( {{{- \mu}x_{2}} + {\left( {M + m} \right)gx_{3}} + x_{5} + u} \right)}} \\ {{\overset{.}{x}}_{5} = \overset{.}{d}} \end{matrix} \right.$ y_(m) = C_(m)X wherein, x₁ is the trolley displacement, x₂ is the trolley velocity, x₃ is the spreader sway angle, x₄ is the angle velocity of the spreader sway angle.
 6. The LQR-based anti-sway control method for the hoisting system according to claim 5, characterized in that in order to realize the observation of system state and lumped disturbance, the extended state observer is designed as follows: $\left\{ \begin{matrix} {{\overset{.}{\overset{\hat{}}{x}}}_{1} = {{\overset{\hat{}}{x}}_{2} + {l_{1}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{2} = {{\frac{1}{M}\left( {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {mg{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right)} + {l_{2}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{3} = {{\overset{\hat{}}{x}}_{4} + {l_{3}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{4} = {{- {\frac{1}{Ml}\left\lbrack {{{- \mu}{\overset{\hat{}}{x}}_{2}} + {\left( {M + m} \right)g{\overset{\hat{}}{x}}_{3}} + {\overset{\hat{}}{x}}_{5} + u} \right\rbrack}} + {l_{4}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}}} \\ {{\overset{.}{\overset{\hat{}}{x}}}_{5} = {l_{5}\left( {{\overset{\hat{}}{x}}_{1} - x_{1}} \right)}} \end{matrix} \right.$ wherein, {circumflex over (x)}₁, {circumflex over (x)}₂, {circumflex over (x)}₃, {circumflex over (x)}₄, {circumflex over (x)}₅ is the observed value of x₁, x₂, x₃, x₄, x₅, l₁, l₂, l₃, l₄, l₅ is the observer gain to be designed.
 7. The LQR-based anti-sway control method for the hoisting system according to claim 1, characterized in that tracking the planned real-time path of the trolley by a Q matrix and an R matrix using a linear quadratic regulator controller comprising the use of the following composite control: u=K_(x)[{circumflex over (x)}₁, {circumflex over (x)}₂, {circumflex over (x)}₃, {circumflex over (x)}₄]−{circumflex over (x)}₅ wherein, K_(x) is the feedback control gain.
 8. A LQR-based anti-sway control system for a hoisting system, characterized in that comprising: a server which comprising a memory, a processor and a computer program stored on the memory and running on the processor,when the the program executed by the processor, the method of claim 1 is executed.
 9. A non-transitory computer readable storage medium on which a computer program is stored, characterized in that when the program is executed by a processor, the method of claim 1 is executed. 